# ！ /usr/bin/python3
# -*- coding:utf-8 -*-
# @Author:Peng Cao
# @File: 001accss_token.py
# @Software: PyCharm
"""
获取access_token
"""
import requests

corpId = "ww2f6508cb56350a90"  # 企业ID
secret_customer = "0kmu8SIwv29M5Jy8g_fkkzfk77rwE1Q_ia8UCR9_SuQ"  # 应用的凭证密钥

params = {'corpid': corpId, 'corpsecret': secret_customer}
res = requests.get(url="https://qyapi.weixin.qq.com/cgi-bin/gettoken", params=params)
access_token = res.json()["access_token"]
print(res.json())
print(access_token)
